summaryrefslogtreecommitdiffstats
path: root/COMPILING.md
diff options
context:
space:
mode:
authorMattes D <github@xoft.cz>2014-02-13 06:59:07 +0100
committerMattes D <github@xoft.cz>2014-02-13 06:59:07 +0100
commitcc72b656c97d82eca0900c19280cdd031cfa7ff4 (patch)
treef2353165f1524ce0a6940258d60b45758ad6e893 /COMPILING.md
parentMerge pull request #668 from tonibm19/patch-1 (diff)
downloadcuberite-cc72b656c97d82eca0900c19280cdd031cfa7ff4.tar
cuberite-cc72b656c97d82eca0900c19280cdd031cfa7ff4.tar.gz
cuberite-cc72b656c97d82eca0900c19280cdd031cfa7ff4.tar.bz2
cuberite-cc72b656c97d82eca0900c19280cdd031cfa7ff4.tar.lz
cuberite-cc72b656c97d82eca0900c19280cdd031cfa7ff4.tar.xz
cuberite-cc72b656c97d82eca0900c19280cdd031cfa7ff4.tar.zst
cuberite-cc72b656c97d82eca0900c19280cdd031cfa7ff4.zip
Diffstat (limited to 'COMPILING.md')
-rw-r--r--COMPILING.md30
1 files changed, 22 insertions, 8 deletions
diff --git a/COMPILING.md b/COMPILING.md
index eceeefee7..d3c896bdd 100644
--- a/COMPILING.md
+++ b/COMPILING.md
@@ -49,7 +49,7 @@ There's a script file, `MCServer/profile_run.cmd` that encapsulates most of the
Install git, cmake and gcc or clang, using your platform's package manager:
```
-sudo apt-get install git cmake gcc
+sudo apt-get install git cmake gcc g++
```
### Getting the sources ###
@@ -65,17 +65,29 @@ git submodule update
Release mode is preferred for almost all cases, it has much better speed and less console spam. However, if you are developing MCServer actively, debug mode might be better.
- cmake . -DCMAKE_BUILD_TYPE=RELEASE && make
-
+Assuming you are in the MCServer folder created in the initial setup step, you need to run these commands:
+```
+mkdir Release
+cd Release
+cmake . -DCMAKE_BUILD_TYPE=RELEASE .. && make
+```
+The executable will be built in the `MCServer/MCServer` folder and will be named `MCServer`.
+
### Debug Mode ###
-Debug mode is useful if you want more debugging information about MCServer as it's running or if you want to use a debugger like GDB to debug issues and crashes.
+Debug mode is useful if you want more debugging information about MCServer while it's running or if you want to use a debugger like GDB to debug issues and crashes.
- cmake . -DCMAKE_BUILD_TYPE=DEBUG && make
+Assuming you are in the MCServer folder created in the Getting the sources step, you need to run these commands:
+```
+mkdir Debug
+cd Debug
+cmake . -DCMAKE_BUILD_TYPE=DEBUG && make`
+```
+The executable will be built in the `MCServer/MCServer` folder and will be named `MCServer_debug`.
-### 32 Bit Mode ###
+### 32 Bit Mode switch ###
-This is useful if you want to compile MCServer to use on another 32-bit machine. It can be used with debug or release mode. To use 32 bit mode, simply add:
+This is useful if you want to compile MCServer on an x64 (64-bit Intel) machine but want to use on an x86 (32-bit Intel) machine. This switch can be used with debug or release mode. Simply add:
-DFORCE_32=1
@@ -84,8 +96,10 @@ to your cmake command and 32 bit will be forced.
### Compiling for another computer ###
-When compiling for another computer it is important to set cross compiling mode. This tells the compiler not to optimise for your machine. It can be used with debug or release mode. To enable simply add:
+When cross-compiling for another computer it is important to set cross compiling mode. This tells the compiler not to optimise for your machine. This switch can be used with debug or release mode. To enable, simply add:
-DCROSSCOMPILE=1
to your cmake command.
+
+Note that cross-compilation is probably broken at this moment, since the build requires running an executable that it has built, as part of the build process.